//
//  CurrencyExchangeJaGmo.h
//  DataCollector
//
//  Created by jiro on 12/07/07.
//  Copyright 2012 jiro music. All rights reserved.
//

#import <Cocoa/Cocoa.h>

#import "DbExchangeTableEntry.h"

class CurrencyExchangeGmo : public DbExchangeTableEntry
{
public:

	static NSString* tableName();
	static NSString* queryCreateTable();
	static NSString* queryFieldsOfCreateTable();
	static NSString* queryInsertInitialValues();
	static NSString* querySelectAll( const std::vector< ClauseNode >& clauses );
	static NSString* querySelect( const std::vector< FieldNode >& fieldNodes, const std::vector< ClauseNode >& clauses );

	static std::vector< NSString* > queriesSelectAll( NSString* currencyCode, NSString* targetCurrencyCode, NSDate* startDate, NSDate* endDate, double intervalSec );
	
	CurrencyExchangeGmo();
	CurrencyExchangeGmo( const DbExchangeTableEntry& entry  );
	CurrencyExchangeGmo( std::vector< const char* > values );
	NSString* sqlInsertStatement() const;
	NSString* queryInsertValue() const;
};
